
var bbbbb = false ;

function changeTNStyle(me,id,lightBGColor,lightTXTColor,blurBGColor,blurTXTColor){
	if(bbbbb){
		return ;
	}
	
	bbbbb = true ;

	if(me.style.backgroundColor == lightBGColor){
		bbbbb = false ;
		return ;
	}

	var newIndex = me.cellIndex ;
	var oldIndex = 0 ;
	for(var i=0;i<20;i++){
		var col = document.getElementById("TNTab_"+id+"_"+i);
		if(col == null){
			bbbbb = false ;
			return ;
		}
		// alert(col.style.backgroundColor+","+lightBGColor);
		if(col.style.backgroundColor == lightBGColor){
			oldIndex = col.cellIndex ;
			col.style.backgroundColor = blurBGColor;
			col.style.color = blurTXTColor ;
			break ;
		}
		
	}
	
	me.style.backgroundColor = lightBGColor;
	me.style.color = lightTXTColor ;

	// alert(newIndex+","+oldIndex);

	var newDiv = document.getElementById("TNDiv_"+id+"_"+newIndex);
	var oldDiv = document.getElementById("TNDiv_"+id+"_"+oldIndex);

	if(newDiv != null){
		newDiv.style.display = "block";
	}
	if(oldDiv != null){
		oldDiv.style.display = "none";
	}
	
	bbbbb = false ;
}